/**
 * 
 */
package org.jrm.map;

import org.jrm.mechanics.Digable;
import org.jrm.mechanics.GameContext;
import org.jrm.mechanics.GameItem;
import org.jrm.mechanics.GameItemsVisitor;

/**
 * @author LAP
 *
 */
public class Wall implements GameItem, Digable {
	private int health;
	/* (non-Javadoc)
	 * @see org.jmb.map.Destructable#Destroy(org.jmb.map.GameContext)
	 */
	@Override
	public void Destroy(GameContext context) {
		
	}

	public int getHealth() {
		return health;
	}

	/* (non-Javadoc)
	 * @see org.jmb.map.Digable#Digg(org.jmb.map.GameContext)
	 */
	@Override
	public void Digg(GameContext context) {
		// TODO Auto-generated method stub

	}

	@Override
	public void accept(GameItemsVisitor visitor) {
		visitor.visitWall(this);
	}
	
	public Wall(int health) {
		if (health <= 0) throw new IllegalArgumentException("Wall health must be more then 0");
		this.health = health;
	}
}
